function  [G,V,S,U,P] = CalculateP(clusters,sigma)

G={};
U ={};
S={};
V={};
P={};
[n1,n2]=size(clusters);
for i=1:n2
    for j=1:n2
        if(i==j)
            continue;
        end
        G{i,j}=CalculateG(clusters{i},clusters{j},sigma);
        [u,s,v]=svd(G{i,j});
        V{i,j}=v;
        S{i,j}=s;
        U{i,j}=u;
        P{i,j}=u*eye(size(s))*v;
    end
end